package modelLag;
import modelLag.*;


/**
 * Write a description of class DVD here.
 * 
 * @author (your name) 
 * @version (a version number or a date)
 */
public class Loan {
    // Initialize parameters
    private int serialNumber;
    private String loanName, loanDate, returnDate;
    // private Person person;
    
    private Copy copy;
    
    /**
     * Loan Constructor
     * 
     * Opretter et lån, med start dato og en periode sat i 'int' så det det kommer til at hedde
     * ex.
     * lånt 03/11/14 periode '7' dage.
     * altså kan vi lave en aflevering dato der er 03/11/14 + 7 dage
     *  
     * boolean er til at sætte status til udlånt.
     */
    public Loan(String loanName, int serialNumber, String loanDate, String returnDate) {
        this.loanName = loanName;
        this.serialNumber = serialNumber;
        this.loanDate = loanDate;
        this.returnDate = returnDate;
        
        // this.person
    }
    
    // sets and gets the loan name
    public void setLoanName(String loanName) {
        this.loanName = loanName;
    }
    public String getLoanName() {
        return loanName;
    }
    
    // sets and gets the loan date
    public void setLoanDate(String loanDate) {
        this.loanDate = loanDate;
    }
    public String GetLoanDate() {
        return loanDate;
    }
    
    // sets and gets the return date
    public void setReturnDate(String returnDate) {
        this.returnDate = returnDate;
    }
    public String getReturnDate() {
        return returnDate;
    }
    
    // sets and gets the serial number
    public void setSerialNumber(int serialNumber) {
        this.serialNumber = serialNumber;
    }
    public int getSerialNumber() {
        return serialNumber;
    }
    
    public void getLoaner() {
        
    }
    
    public void addCopy() {
        copy.getSerial();
    }

    public void printLoanInfo() {
        System.out.println("-------------------------------------------------"+"\n");
        System.out.println(" Loan Name   :   "+ loanName +"\n");
        System.out.println(" Loan Date   :   "+ loanDate +"\n");
        System.out.println(" Return Date :   "+ returnDate +"\n");
        System.out.println(" Serial No.  :   "+ serialNumber +"\n");
        System.out.println("-------------------------------------------------"+"\n");
    }
}
